<select name="time">
  <option value="12:00 am">12:00 AM</option>
<?php
 for($time = 1; $time <= 60*60*23 ; $time=$time+60*60) {
    echo '<option value="'.date('h:i a', $time).'">'.date('h:i a', $time).'</option>';
 }
 ?>
</select>
